﻿using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Audio;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.GamerServices;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input;
using Microsoft.Xna.Framework.Media;
using Microsoft.Xna.Framework.Net;
using Microsoft.Xna.Framework.Storage;

namespace _0812045
{
    public class CharacterSprite : BaseSprite
    {
        public CharacterSprite()
        {

        }
        public CharacterSprite(Texture2D[] texture2D)
        {
            _texture2d = texture2D;
            _itexture2d = 0;
            _ntexture2d = texture2D.Length;
            _x = 0;
            _y = 0;
        }
        public override void Update(GameTime gameTime)
        {
            _itexture2d = (_itexture2d + 1) % _ntexture2d;
            //base.Update(gameTime);
        }
        public override void Draw(GameTime gameTime, SpriteBatch spriteBatch)
        {
            spriteBatch.Draw(_texture2d[_itexture2d], new Vector2(_x, _y), Color.White);
            //base.Draw(gameTime, spriteBatch);
        }
    }
}
